SECURITY: Prevent tokens in jsonp mode
authorBrad Jorsch <bjorsch@wikimedia.org>
Thu, 29 Aug 2013 16:45:30 +0000 (09:45 -0700)
committercsteipp <csteipp@wikimedia.org>
Tue, 3 Sep 2013 22:04:47 +0000 (15:04 -0700)
commit43f3ab65cf1252e59766132ccdff9136372386e3
treed810c69a771c58ec7ad899ca42c3d5335ef81528
parent4624b8a0d0629973dc3e2c8a6cb88d3e41f10293
SECURITY: Prevent tokens in jsonp mode

Add checks to token-returning functions to prevent returning tokens in
jsonp mode. This affects action=tokens, action=login,
action=createaccount, and action=query&list=deletedrevs.

Also, remove the "gettoken" parameter to action=block and
action=unblock, which has been deprecated since 1.20.

Bug: 49090
Change-Id: Ibeaa5c72d8084585092b15935a3f5709104bf7f7
RELEASE-NOTES-1.22
includes/api/ApiBlock.php
includes/api/ApiCreateAccount.php
includes/api/ApiLogin.php
includes/api/ApiMain.php
includes/api/ApiQueryDeletedrevs.php
includes/api/ApiTokens.php
includes/api/ApiUnblock.php
tests/phpunit/includes/api/ApiBlockTest.php